<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml">
		<head>
			<!-- template designed by Marco Von Ballmoos -->
			<title>Docs For Class Swift_Connection_Multi</title>
			<link rel="stylesheet" href="../media/stylesheet.css" />
			<meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/>
		</head>
		<body>
			<div class="page-body">			
<h2 class="class-name">Class Swift_Connection_Multi</h2>

<a name="sec-description"></a>
<div class="info-box">
	<div class="info-box-title">Description</div>
	<div class="nav-bar">
					<span class="disabled">Description</span> |
													<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
						|											<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
						
					</div>
	<div class="info-box-body">
        		<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Swift Multi Connection</p>
<p class="description"><p>Tries to connect to a number of connections until one works successfully</p></p>
	<ul class="tags">
				<li><span class="field">author:</span> Chris Corbyn &lt;<a href="mailto:chris@w3style.co.uk">chris@w3style.co.uk</a>&gt;</li>
			</ul>
		<p class="notes">
			Located in <a class="field" href="_Swift---Connection---Multi.php.html">/Swift/Connection/Multi.php</a> (line <span class="field">20</span>)
		</p>
		
				
		<pre><a href="../Swift_Connection/Swift_Connection.html">Swift_Connection</a>
   |
   --<a href="../Swift_Connection/Swift_ConnectionBase.html">Swift_ConnectionBase</a>
      |
      --Swift_Connection_Multi</pre>
	
			</div>
</div>



	<a name="sec-var-summary"></a>
	<div class="info-box">
		<div class="info-box-title">Variable Summary</span></div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
						<span class="disabled">Vars</span> (<a href="#sec-vars">details</a>)
							| 
									<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
							
								</div>
		<div class="info-box-body">
			<div class="var-summary">
																																<div class="var-title">
					<span class="var-type">string</span>
					<a href="#$active" title="details" class="var-name">$active</a>
				</div>
																<div class="var-title">
					<span class="var-type">array</span>
					<a href="#$connections" title="details" class="var-name">$connections</a>
				</div>
											</div>
		</div>
	</div>

	<a name="sec-method-summary"></a>
	<div class="info-box">
		<div class="info-box-title">Method Summary</span></div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
																		<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
				 
				|
						<span class="disabled">Methods</span> (<a href="#sec-methods">details</a>)
		</div>
		<div class="info-box-body">			
			<div class="method-summary">
																																																																																												
												<div class="method-definition">
											<span class="method-result">Swift_Connection_Multi</span>
										<a href="#Swift_Connection_Multi" title="details" class="method-name">Swift_Connection_Multi</a>
											([<span class="var-type"></span>&nbsp;<span class="var-name">$connections</span> = <span class="var-default">array()</span>])
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#addConnection" title="details" class="method-name">addConnection</a>
											(<span class="var-type"><a href="../Swift_Connection/Swift_Connection.html">Swift_Connection</a></span>&nbsp;<span class="var-name">&$connection</span>, [<span class="var-type">string</span>&nbsp;<span class="var-name">$id</span> = <span class="var-default">null</span>])
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#getAttributes" title="details" class="method-name">getAttributes</a>
											(<span class="var-type"></span>&nbsp;<span class="var-name">$name</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#hasExtension" title="details" class="method-name">hasExtension</a>
											(<span class="var-type"></span>&nbsp;<span class="var-name">$name</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">boolean</span>
										<a href="#isAlive" title="details" class="method-name">isAlive</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#postConnect" title="details" class="method-name">postConnect</a>
											(<span class="var-type"></span>&nbsp;<span class="var-name">&$instance</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">string</span>
										<a href="#read" title="details" class="method-name">read</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#setExtension" title="details" class="method-name">setExtension</a>
											(<span class="var-type"></span>&nbsp;<span class="var-name">$extension</span>, [<span class="var-type"></span>&nbsp;<span class="var-name">$attributes</span> = <span class="var-default">array()</span>])
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#start" title="details" class="method-name">start</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#stop" title="details" class="method-name">stop</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#write" title="details" class="method-name">write</a>
											(<span class="var-type">string</span>&nbsp;<span class="var-name">$command</span>, [<span class="var-type"></span>&nbsp;<span class="var-name">$end</span> = <span class="var-default">&quot;\r\n&quot;</span>])
									</div>
								</div>
		</div>
	</div>		

	<a name="sec-vars"></a>
	<div class="info-box">
		<div class="info-box-title">Variables</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
										<a href="#sec-var-summary">Vars</a> (<span class="disabled">details</span>)
						
			
										| 
									<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
							
					</div>
		<div class="info-box-body">
			<a name="var$active" id="$active"><!-- --></A>
<div class="oddrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">string</span>
			<span class="var-name">$active</span>
			 = <span class="var-default"> null</span>			(line <span class="line-number">31</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">The id of the active connection</p>
	
	
		
		

</div>
<a name="var$connections" id="$connections"><!-- --></A>
<div class="evenrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">array</span>
			<span class="var-name">$connections</span>
			 = <span class="var-default">array()</span>			(line <span class="line-number">26</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">The list of available connections</p>
	
	
		
		

</div>
							<h4>Inherited Variables</h4>
				<A NAME='inherited_vars'><!-- --></A>
									<p>Inherited from <span class="classname"><a href="../Swift_Connection/Swift_ConnectionBase.html">Swift_ConnectionBase</a></span></p>
					<blockquote>
													<span class="var-title">
								<span class="var-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#var$extensions">Swift_ConnectionBase::$extensions</a></span><br>
							</span>
													<span class="var-title">
								<span class="var-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#var$isESMTP">Swift_ConnectionBase::$isESMTP</a></span><br>
							</span>
											</blockquote> 
										
		</div>
	</div>
	
	<a name="sec-methods"></a>
	<div class="info-box">
		<div class="info-box-title">Methods</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
															<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
																	<a href="#sec-method-summary">Methods</a> (<span class="disabled">details</span>)
						
		</div>
		<div class="info-box-body">
			<A NAME='method_detail'></A>

<a name="methodSwift_Connection_Multi" id="Swift_Connection_Multi"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">Constructor Swift_Connection_Multi</span> (line <span class="line-number">36</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Constructor</p>
	
	<div class="method-signature">
		<span class="method-result">Swift_Connection_Multi</span>
		<span class="method-name">
			Swift_Connection_Multi
		</span>
					([<span class="var-type"></span>&nbsp;<span class="var-name">$connections</span> = <span class="var-default">array()</span>])
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"></span>
				<span class="var-name">$connections</span>			</li>
				</ul>
		
			
	</div>
<a name="methodaddConnection" id="addConnection"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">addConnection</span> (line <span class="line-number">48</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Add a connection to the list of options</p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			addConnection
		</span>
					(<span class="var-type"><a href="../Swift_Connection/Swift_Connection.html">Swift_Connection</a></span>&nbsp;<span class="var-name">&$connection</span>, [<span class="var-type">string</span>&nbsp;<span class="var-name">$id</span> = <span class="var-default">null</span>])
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"><a href="../Swift_Connection/Swift_Connection.html">Swift_Connection</a></span>
				<span class="var-name">&$connection</span><span class="var-description">: An instance of the connection</span>			</li>
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$id</span><span class="var-description">: An ID to assign to the connection</span>			</li>
				</ul>
		
			
	</div>
<a name="methodgetAttributes" id="getAttributes"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">getAttributes</span> (line <span class="line-number">167</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Call the current connection's getAttributes() method</p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			getAttributes
		</span>
					(<span class="var-type"></span>&nbsp;<span class="var-name">$name</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"></span>
				<span class="var-name">$name</span>			</li>
				</ul>
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_ConnectionBase.html#methodgetAttributes">Swift_ConnectionBase::getAttributes()</a></dt>
						<dd>Get the list of attributes supported by the given extension</dd>
					</dl>
			
	</div>
<a name="methodhasExtension" id="hasExtension"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">hasExtension</span> (line <span class="line-number">160</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Call the current connection's hasExtension() method</p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			hasExtension
		</span>
					(<span class="var-type"></span>&nbsp;<span class="var-name">$name</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"></span>
				<span class="var-name">$name</span>			</li>
				</ul>
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_ConnectionBase.html#methodhasExtension">Swift_ConnectionBase::hasExtension()</a></dt>
						<dd>Check if a given extension has been set as available</dd>
					</dl>
			
	</div>
<a name="methodisAlive" id="isAlive"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">isAlive</span> (line <span class="line-number">139</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Check if the current connection is alive</p>
	
	<div class="method-signature">
		<span class="method-result">boolean</span>
		<span class="method-name">
			isAlive
		</span>
				()
			</div>
	
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_Connection.html#methodisAlive">Swift_Connection::isAlive()</a></dt>
						<dd>Check if the connection is up or not</dd>
					</dl>
			
	</div>
<a name="methodpostConnect" id="postConnect"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">postConnect</span> (line <span class="line-number">146</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Call the current connection's postConnect() method</p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			postConnect
		</span>
					(<span class="var-type"></span>&nbsp;<span class="var-name">&$instance</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"></span>
				<span class="var-name">&$instance</span>			</li>
				</ul>
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_ConnectionBase.html#methodpostConnect">Swift_ConnectionBase::postConnect()</a></dt>
						<dd>Execute any needed logic after connecting and handshaking</dd>
					</dl>
			
	</div>
<a name="methodread" id="read"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">read</span> (line <span class="line-number">68</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Read a full response from the buffer</p>
	<ul class="tags">
				<li><span class="field">throws:</span> Swift_ConnectionException Upon failure to read</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">string</span>
		<span class="method-name">
			read
		</span>
				()
			</div>
	
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_Connection.html#methodread">Swift_Connection::read()</a></dt>
						<dd>Return the contents of the buffer</dd>
					</dl>
			
	</div>
<a name="methodsetExtension" id="setExtension"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">setExtension</span> (line <span class="line-number">153</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Call the current connection's setExtension() method</p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			setExtension
		</span>
					(<span class="var-type"></span>&nbsp;<span class="var-name">$extension</span>, [<span class="var-type"></span>&nbsp;<span class="var-name">$attributes</span> = <span class="var-default">array()</span>])
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"></span>
				<span class="var-name">$extension</span>			</li>
					<li>
				<span class="var-type"></span>
				<span class="var-name">$attributes</span>			</li>
				</ul>
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_ConnectionBase.html#methodsetExtension">Swift_ConnectionBase::setExtension()</a></dt>
						<dd>Set an extension which the connection reports to support</dd>
					</dl>
			
	</div>
<a name="methodstart" id="start"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">start</span> (line <span class="line-number">97</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Try to start the connection</p>
	<ul class="tags">
				<li><span class="field">throws:</span> Swift_ConnectionException Upon failure to start</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			start
		</span>
				()
			</div>
	
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_Connection.html#methodstart">Swift_Connection::start()</a></dt>
						<dd>Try to start the connection</dd>
					</dl>
			
	</div>
<a name="methodstop" id="stop"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">stop</span> (line <span class="line-number">130</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Try to close the connection</p>
	<ul class="tags">
				<li><span class="field">throws:</span> Swift_ConnectionException Upon failure to close</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			stop
		</span>
				()
			</div>
	
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_Connection.html#methodstop">Swift_Connection::stop()</a></dt>
						<dd>Try to stop the connection</dd>
					</dl>
			
	</div>
<a name="methodwrite" id="write"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">write</span> (line <span class="line-number">83</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Write a command to the server (leave off trailing CRLF)</p>
	<ul class="tags">
				<li><span class="field">throws:</span> Swift_ConnectionException Upon failure to write</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			write
		</span>
					(<span class="var-type">string</span>&nbsp;<span class="var-name">$command</span>, [<span class="var-type"></span>&nbsp;<span class="var-name">$end</span> = <span class="var-default">&quot;\r\n&quot;</span>])
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$command</span><span class="var-description">: The command to send</span>			</li>
					<li>
				<span class="var-type"></span>
				<span class="var-name">$end</span>			</li>
				</ul>
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_Connection.html#methodwrite">Swift_Connection::write()</a></dt>
						<dd>Write a command to the buffer</dd>
					</dl>
			
	</div>
							<h4>Inherited Methods</h4>
				<a name='inherited_methods'><!-- --></a>	
									<!-- =========== Summary =========== -->
					<p>Inherited From <span class="classname"><a href="../Swift_Connection/Swift_ConnectionBase.html">Swift_ConnectionBase</a></span></p>
					<blockquote>
													<span class="method-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#methodgetAttributes">Swift_ConnectionBase::getAttributes()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#methodgetRequiresEHLO">Swift_ConnectionBase::getRequiresEHLO()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#methodhasExtension">Swift_ConnectionBase::hasExtension()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#methodpostConnect">Swift_ConnectionBase::postConnect()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#methodsetExtension">Swift_ConnectionBase::setExtension()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#methodsetRequiresEHLO">Swift_ConnectionBase::setRequiresEHLO()</a></span><br>
											</blockquote>
									<!-- =========== Summary =========== -->
					<p>Inherited From <span class="classname"><a href="../Swift_Connection/Swift_Connection.html">Swift_Connection</a></span></p>
					<blockquote>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodgetAttributes">Swift_Connection::getAttributes()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodgetRequiresEHLO">Swift_Connection::getRequiresEHLO()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodhasExtension">Swift_Connection::hasExtension()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodisAlive">Swift_Connection::isAlive()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodpostConnect">Swift_Connection::postConnect()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodread">Swift_Connection::read()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodsetExtension">Swift_Connection::setExtension()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodsetRequiresEHLO">Swift_Connection::setRequiresEHLO()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodstart">Swift_Connection::start()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodstop">Swift_Connection::stop()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodwrite">Swift_Connection::write()</a></span><br>
											</blockquote>
										
		</div>
	</div>


	<p class="notes" id="credit">
		Documentation generated on Wed, 26 Mar 2008 20:33:50 +1100 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.3.1</a>
	</p>
	</div></body>
</html>